package com.dwxt.cdms.entity.yumeng;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.experimental.Accessors;

import javax.persistence.Column;
import javax.persistence.Id;
import javax.persistence.Table;
import java.time.LocalDateTime;

/**
 * 翎盟-睡眠统计
 *
 * @author Kuang.JiaZhuo
 * @date 2020-09-09 16:27
 */
@Data
@Accessors(chain = true)
@Table(name = "t_sleep_analysis_stastic")
public class SleepAnalysisStatistics {
    @Id
    private String id;

    /**
     * 睡眠分析数据id
     */
    @Column(name = "sleep_analysis_id")
    private String sleepAnalysisId;

    /**
     * 总睡眠开始时间
     */
    @Column(name = "sleep_start")
    private String sleepStart;

    /**
     * 总睡眠结束时间
     */
    @Column(name = "sleep_end")
    private String sleepEnd;

    /**
     * 总睡眠持续时间(分钟)
     */
    @Column(name = "sleep_duration")
    private Integer sleepDuration;

    /**
     * 总浅睡眠持续时间(分钟)
     */
    @Column(name = "n2_phase_duration")
    private Integer n2PhaseDuration;

    /**
     * 总深睡眠持续时间(分钟)
     */
    @Column(name = "n3_phase_duration")
    private Integer n3PhaseDuration;

    /**
     * 总快速眼动睡眠持续时间(分钟)
     */
    @Column(name = "rphase_duration")
    private Integer rphaseDuration;

    /**
     * 总清醒睡眠持续时间(分钟)
     */
    @Column(name = "wphase_duration")
    private String wphaseDuration;

    /**
     * 创建时间(录入数据库的时间)
     */
    @Column(name = "create_time")
    @JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone="GMT+8")
    private LocalDateTime createTime;

    /**
     * 逻辑删除标识(0否1是)
     */
    @Column(name = "is_delete")
    private String isDelete;


    /**
     * 备用字段1
     */
    @Column(name = "spare_field_1")
    private String spareField1;

    /**
     * 备用字段2
     */
    @Column(name = "spare_field_2")
    private String spareField2;

    /**
     * 备用字段3
     */
    @Column(name = "spare_field_3")
    private String spareField3;
}